﻿using FreeSql.DatabaseModel;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using Newtonsoft.Json;
using FreeSql.DataAnnotations;

namespace LeafCore.Entities {

	/// <summary>
	/// 用户信息表
	/// </summary>
	[JsonObject(MemberSerialization.OptIn), Table(Name = "t_user", DisableSyncStructure = true)]
	public partial class TUser {

		/// <summary>
		/// 主键
		/// </summary>
		[JsonProperty, Column(IsPrimary = true, IsIdentity = true)]
		public int Id { get; set; }

		/// <summary>
		/// 年龄
		/// </summary>
		[JsonProperty]
		public int Age { get; set; }

		/// <summary>
		/// 创建时间
		/// </summary>
		[JsonProperty, Column(DbType = "datetime", InsertValueSql = "CURRENT_TIMESTAMP")]
		public DateTime CreateTime { get; set; }

		/// <summary>
		/// 邮箱
		/// </summary>
		[JsonProperty]
		public string Email { get; set; }

		/// <summary>
		/// 是否删除
		/// </summary>
		[JsonProperty]
		public bool IsDeleted { get; set; } = false;

		/// <summary>
		/// 姓名
		/// </summary>
		[JsonProperty, Column(IsNullable = false)]
		public string Name { get; set; }

		/// <summary>
		/// 密码
		/// </summary>
		[JsonProperty, Column(IsNullable = false)]
		public string Password { get; set; }

		/// <summary>
		/// 手机号
		/// </summary>
		[JsonProperty]
		public string Phone { get; set; }

		/// <summary>
		/// 0.未知 1.男 2.女
		/// </summary>
		[JsonProperty]
		public int Sex { get; set; }

		/// <summary>
		/// 更新时间
		/// </summary>
		[JsonProperty, Column(DbType = "datetime")]
		public DateTime UpdateTime { get; set; }

		/// <summary>
		/// 用户名
		/// </summary>
		[JsonProperty, Column(IsNullable = false)]
		public string UserName { get; set; }

		/// <summary>
		/// 微信编号
		/// </summary>
		[JsonProperty, Column(IsNullable = false)]
		public string WatchId { get; set; }

	}

}
